import axios from 'axios';

const request = axios.create({
  // baseURL: import.meta.env.VITE_APP_BASE_URL,
  baseURL: '/api',
  timeout: 10000,
  headers: {
    Authorization: localStorage.getItem('token')
  }
})

request.interceptors.request.use(config => {
  return config
})

request.interceptors.response.use(response => {
  return response.data
})

export default request